The next operation is choice, for which the operator is |
.
It has the lowest priority of all. Entering x | y | z
produces
With this operator, parentheses are significant. The expressions
( x | y ) | z
and x | ( y | z )
produce
and
respectively, which have a different layout (but represent the same
language).
Related to choice are priority annonations, of the form
[string]. An example of their use can be seen in the
railroad diagram for body. They should only be used with the
top-level choice of a rule body, since otherwise their meaning is
not clear. As an example, [1] x y | [2] z
produces
When used with identifiers as in body[2--5]
they produce
The string between [
and ]
may not contain tabs,
newlines or ]
. Remember that you should use --
to produce a number dash (see LATEX: A Document Preparation System,
page 14).